#include <stdio.h>
int main(void)
{
	int num,temp,number_length = 33;
	char num2[number_length];
	num2[0] = '0';
	scanf("%d",&num);
	temp = (num>0) ? num : (-1 * num);
	for(int i = number_length - 2;i > 0;i--)
	{
		num2[i] = (temp%2 == 0) ? '0' : '1';
		temp/=2;	
	}
	if(num<0)
	{
		int tempNum=0;
		for(int i = 1; i < number_length - 1;i++)
		{
			temp = ('1' == num2[i]) ? 0 : 1;
			//temp = ('1' == num2[i]) ? 1 : 0;
			tempNum = tempNum * 2 + temp;
		}
		tempNum += 1;
		for(int i = number_length - 2;i > 0;i--)
        	{       
                	num2[i] = (tempNum%2 == 0) ? '0' : '1';
                	tempNum/=2;
        	}
	}
	num2[0] = (num>0) ? '0' : '1';
	printf("%s\n",num2);
	return 0;
}
